#include <ncurses.h>
#include <stdint.h>
#include <stdlib.h>
#include "util.h"

int main()
{
	WINDOW* game_window;
	int maxy;
	int maxx;

	if (! init_curses(&maxy, &maxx))
		return EXIT_FAILURE;

	game_window = newwin(24, 80, 0, 0);
	box(game_window, 0, 0);
	wnoutrefresh(game_window);
	doupdate();

	while (handle_input(game_window, &maxy, &maxx)) {
		doupdate();
	};
	
	delwin(game_window);
	endwin();

	printf("%ix%i\n", maxy, maxx);
	return EXIT_SUCCESS;
}

